/*
 * XML Type:  embeddable
 * Namespace: http://java.sun.com/xml/ns/persistence/orm
 * Java type: com.googlecode.horncomb.orm.jpa.v10.xmlbeans.Embeddable
 *
 * Automatically generated - do not modify.
 */
package com.googlecode.horncomb.orm.jpa.v10.xmlbeans.impl;
/**
 * An XML embeddable(@http://java.sun.com/xml/ns/persistence/orm).
 *
 * This is a complex type.
 */
public class EmbeddableImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements com.googlecode.horncomb.orm.jpa.v10.xmlbeans.Embeddable
{
    
    /**  */
	private static final long serialVersionUID = -7069106912944335397L;


	public EmbeddableImpl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName DESCRIPTION$0 = 
        new javax.xml.namespace.QName("http://java.sun.com/xml/ns/persistence/orm", "description");
    private static final javax.xml.namespace.QName ATTRIBUTES$2 = 
        new javax.xml.namespace.QName("http://java.sun.com/xml/ns/persistence/orm", "attributes");
    private static final javax.xml.namespace.QName CLASS1$4 = 
        new javax.xml.namespace.QName("", "class");
    private static final javax.xml.namespace.QName ACCESS$6 = 
        new javax.xml.namespace.QName("", "access");
    private static final javax.xml.namespace.QName METADATACOMPLETE$8 = 
        new javax.xml.namespace.QName("", "metadata-complete");
    
    
    /**
     * Gets the "description" element
     */
    public java.lang.String getDescription()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(DESCRIPTION$0, 0);
            if (target == null)
            {
                return null;
            }
            return target.getStringValue();
        }
    }
    
    /**
     * Gets (as xml) the "description" element
     */
    public org.apache.xmlbeans.XmlString xgetDescription()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlString target = null;
            target = (org.apache.xmlbeans.XmlString)get_store().find_element_user(DESCRIPTION$0, 0);
            return target;
        }
    }
    
    /**
     * True if has "description" element
     */
    public boolean isSetDescription()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(DESCRIPTION$0) != 0;
        }
    }
    
    /**
     * Sets the "description" element
     */
    public void setDescription(java.lang.String description)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(DESCRIPTION$0, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(DESCRIPTION$0);
            }
            target.setStringValue(description);
        }
    }
    
    /**
     * Sets (as xml) the "description" element
     */
    public void xsetDescription(org.apache.xmlbeans.XmlString description)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlString target = null;
            target = (org.apache.xmlbeans.XmlString)get_store().find_element_user(DESCRIPTION$0, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.XmlString)get_store().add_element_user(DESCRIPTION$0);
            }
            target.set(description);
        }
    }
    
    /**
     * Unsets the "description" element
     */
    public void unsetDescription()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(DESCRIPTION$0, 0);
        }
    }
    
    /**
     * Gets the "attributes" element
     */
    public com.googlecode.horncomb.orm.jpa.v10.xmlbeans.EmbeddableAttributes getAttributes()
    {
        synchronized (monitor())
        {
            check_orphaned();
            com.googlecode.horncomb.orm.jpa.v10.xmlbeans.EmbeddableAttributes target = null;
            target = (com.googlecode.horncomb.orm.jpa.v10.xmlbeans.EmbeddableAttributes)get_store().find_element_user(ATTRIBUTES$2, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * True if has "attributes" element
     */
    public boolean isSetAttributes()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(ATTRIBUTES$2) != 0;
        }
    }
    
    /**
     * Sets the "attributes" element
     */
    public void setAttributes(com.googlecode.horncomb.orm.jpa.v10.xmlbeans.EmbeddableAttributes attributes)
    {
        synchronized (monitor())
        {
            check_orphaned();
            com.googlecode.horncomb.orm.jpa.v10.xmlbeans.EmbeddableAttributes target = null;
            target = (com.googlecode.horncomb.orm.jpa.v10.xmlbeans.EmbeddableAttributes)get_store().find_element_user(ATTRIBUTES$2, 0);
            if (target == null)
            {
                target = (com.googlecode.horncomb.orm.jpa.v10.xmlbeans.EmbeddableAttributes)get_store().add_element_user(ATTRIBUTES$2);
            }
            target.set(attributes);
        }
    }
    
    /**
     * Appends and returns a new empty "attributes" element
     */
    public com.googlecode.horncomb.orm.jpa.v10.xmlbeans.EmbeddableAttributes addNewAttributes()
    {
        synchronized (monitor())
        {
            check_orphaned();
            com.googlecode.horncomb.orm.jpa.v10.xmlbeans.EmbeddableAttributes target = null;
            target = (com.googlecode.horncomb.orm.jpa.v10.xmlbeans.EmbeddableAttributes)get_store().add_element_user(ATTRIBUTES$2);
            return target;
        }
    }
    
    /**
     * Unsets the "attributes" element
     */
    public void unsetAttributes()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(ATTRIBUTES$2, 0);
        }
    }
    
    /**
     * Gets the "class" attribute
     */
    public java.lang.String getClass1()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(CLASS1$4);
            if (target == null)
            {
                return null;
            }
            return target.getStringValue();
        }
    }
    
    /**
     * Gets (as xml) the "class" attribute
     */
    public org.apache.xmlbeans.XmlString xgetClass1()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlString target = null;
            target = (org.apache.xmlbeans.XmlString)get_store().find_attribute_user(CLASS1$4);
            return target;
        }
    }
    
    /**
     * Sets the "class" attribute
     */
    public void setClass1(java.lang.String class1)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(CLASS1$4);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_attribute_user(CLASS1$4);
            }
            target.setStringValue(class1);
        }
    }
    
    /**
     * Sets (as xml) the "class" attribute
     */
    public void xsetClass1(org.apache.xmlbeans.XmlString class1)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlString target = null;
            target = (org.apache.xmlbeans.XmlString)get_store().find_attribute_user(CLASS1$4);
            if (target == null)
            {
                target = (org.apache.xmlbeans.XmlString)get_store().add_attribute_user(CLASS1$4);
            }
            target.set(class1);
        }
    }
    
    /**
     * Gets the "access" attribute
     */
    public com.googlecode.horncomb.orm.jpa.v10.xmlbeans.AccessType.Enum getAccess()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(ACCESS$6);
            if (target == null)
            {
                return null;
            }
            return (com.googlecode.horncomb.orm.jpa.v10.xmlbeans.AccessType.Enum)target.getEnumValue();
        }
    }
    
    /**
     * Gets (as xml) the "access" attribute
     */
    public com.googlecode.horncomb.orm.jpa.v10.xmlbeans.AccessType xgetAccess()
    {
        synchronized (monitor())
        {
            check_orphaned();
            com.googlecode.horncomb.orm.jpa.v10.xmlbeans.AccessType target = null;
            target = (com.googlecode.horncomb.orm.jpa.v10.xmlbeans.AccessType)get_store().find_attribute_user(ACCESS$6);
            return target;
        }
    }
    
    /**
     * True if has "access" attribute
     */
    public boolean isSetAccess()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().find_attribute_user(ACCESS$6) != null;
        }
    }
    
    /**
     * Sets the "access" attribute
     */
    public void setAccess(com.googlecode.horncomb.orm.jpa.v10.xmlbeans.AccessType.Enum access)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(ACCESS$6);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_attribute_user(ACCESS$6);
            }
            target.setEnumValue(access);
        }
    }
    
    /**
     * Sets (as xml) the "access" attribute
     */
    public void xsetAccess(com.googlecode.horncomb.orm.jpa.v10.xmlbeans.AccessType access)
    {
        synchronized (monitor())
        {
            check_orphaned();
            com.googlecode.horncomb.orm.jpa.v10.xmlbeans.AccessType target = null;
            target = (com.googlecode.horncomb.orm.jpa.v10.xmlbeans.AccessType)get_store().find_attribute_user(ACCESS$6);
            if (target == null)
            {
                target = (com.googlecode.horncomb.orm.jpa.v10.xmlbeans.AccessType)get_store().add_attribute_user(ACCESS$6);
            }
            target.set(access);
        }
    }
    
    /**
     * Unsets the "access" attribute
     */
    public void unsetAccess()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_attribute(ACCESS$6);
        }
    }
    
    /**
     * Gets the "metadata-complete" attribute
     */
    public boolean getMetadataComplete()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(METADATACOMPLETE$8);
            if (target == null)
            {
                return false;
            }
            return target.getBooleanValue();
        }
    }
    
    /**
     * Gets (as xml) the "metadata-complete" attribute
     */
    public org.apache.xmlbeans.XmlBoolean xgetMetadataComplete()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlBoolean target = null;
            target = (org.apache.xmlbeans.XmlBoolean)get_store().find_attribute_user(METADATACOMPLETE$8);
            return target;
        }
    }
    
    /**
     * True if has "metadata-complete" attribute
     */
    public boolean isSetMetadataComplete()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().find_attribute_user(METADATACOMPLETE$8) != null;
        }
    }
    
    /**
     * Sets the "metadata-complete" attribute
     */
    public void setMetadataComplete(boolean metadataComplete)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(METADATACOMPLETE$8);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_attribute_user(METADATACOMPLETE$8);
            }
            target.setBooleanValue(metadataComplete);
        }
    }
    
    /**
     * Sets (as xml) the "metadata-complete" attribute
     */
    public void xsetMetadataComplete(org.apache.xmlbeans.XmlBoolean metadataComplete)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlBoolean target = null;
            target = (org.apache.xmlbeans.XmlBoolean)get_store().find_attribute_user(METADATACOMPLETE$8);
            if (target == null)
            {
                target = (org.apache.xmlbeans.XmlBoolean)get_store().add_attribute_user(METADATACOMPLETE$8);
            }
            target.set(metadataComplete);
        }
    }
    
    /**
     * Unsets the "metadata-complete" attribute
     */
    public void unsetMetadataComplete()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_attribute(METADATACOMPLETE$8);
        }
    }
}
